xl: do not run bootloader on restore.
authorIan Campbell <ian.campbell@citrix.com>
Fri, 3 Sep 2010 17:44:49 +0000 (18:44 +0100)
committerIan Campbell <ian.campbell@citrix.com>
Fri, 3 Sep 2010 17:44:49 +0000 (18:44 +0100)
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
tools/libxl/xl_cmdimpl.c

index 3f6219b47b73e7552091f58d9efcbd5acb7a06ff..9393059e710371af13f8bb9043a1f3276b811d3b 100644 (file)
@@ -1402,10 +1402,12 @@ start:
             goto error_out;
     }
 
-    ret = libxl_run_bootloader(&ctx, &d_config.b_info, d_config.num_disks > 0 ? &d_config.disks[0] : NULL, domid);
-    if (ret) {
-        fprintf(stderr, "failed to run bootloader: %d\n", ret);
-        goto error_out;
+    if (!restore_file) {
+        ret = libxl_run_bootloader(&ctx, &d_config.b_info, d_config.num_disks > 0 ? &d_config.disks[0] : NULL, domid);
+        if (ret) {
+            fprintf(stderr, "failed to run bootloader: %d\n", ret);
+            goto error_out;
+        }
     }
 
     if (!restore_file || !need_daemon) {